Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow for configuration of the default view context controller #776

Closed
wants to merge 3 commits into from

Conversation

nickd0
Copy link

@nickd0 nickd0 commented Feb 10, 2017

In response to issues #249 and #573

Allow for configuration of the default view context controller. This is particularly useful for applications without an ApplicationController (ie engine-driven apps). A string is used rather than a constant so that the default_controller can be set anywhere in the initialization process

@codebycliff codebycliff added this to the 3.0.0 milestone Mar 29, 2017
@codebycliff
Copy link
Collaborator

@nick-donald Sorry it took so long to get back to you. Thanks for the contribution. It looks like this has been a pain point for a while now. I was able to test this by adding a new initializer containing Draper::ViewContext.default_controller = 'BaseController'. Is that the process you were imagining? Before I merge this, I'd like to see a few more changes:

  1. Update the Railtie's runner to use the new ViewContext.default_controller
  2. Add tests
  3. Add documentation to the README.

Would you be able to take a stab at these things?

@codebycliff
Copy link
Collaborator

@nick-donald I have continued your work in the following pull request:

#788

Thanks for your help!

@nickd0
Copy link
Author

nickd0 commented Mar 30, 2017

sure 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants